package vista;
import java.awt.BorderLayout;
import java.awt.event.ActionListener;

import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JPanel;

import javax.swing.WindowConstants;
import javax.swing.SwingUtilities;


/**
* This code was edited or generated using CloudGarden's Jigloo
* SWT/Swing GUI Builder, which is free for non-commercial
* use. If Jigloo is being used commercially (ie, by a corporation,
* company or business for any purpose whatever) then you
* should purchase a license for each developer using Jigloo.
* Please visit www.cloudgarden.com for details.
* Use of Jigloo implies acceptance of these licensing terms.
* A COMMERCIAL LICENSE HAS NOT BEEN PURCHASED FOR
* THIS MACHINE, SO JIGLOO OR THIS CODE CANNOT BE USED
* LEGALLY FOR ANY CORPORATE OR COMMERCIAL PURPOSE.
*/
public class Menu extends javax.swing.JFrame {
	private JPanel panelmenu;
	private JButton btnProducto;
	private JButton btnCategoria;
	private JButton btnIngrediente;
	private JButton btnCompra;
	private JButton btnOrden;

	/**
	* Auto-generated main method to display this JFrame
	*/
		
	public Menu() {
		super();
		initGUI();
	}
	
	private void initGUI() {
		try {
			setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
			this.setTitle("Menu Principal");
			getContentPane().setLayout(null);
			{
				panelmenu = new JPanel();
				getContentPane().add(panelmenu);
				panelmenu.setBounds(6, 0, 540, 268);
				panelmenu.setLayout(null);
				{
					btnProducto = new JButton();
					panelmenu.add(btnProducto);
					btnProducto.setText("Producto");
					btnProducto.setBounds(352, 32, 159, 43);
					btnProducto.setIcon(new ImageIcon(getClass().getClassLoader().getResource("imagen/C02-fastfood.png")));
				}
				{
					btnOrden = new JButton();
					panelmenu.add(btnOrden);
					btnOrden.setText("Orden");
					btnOrden.setBounds(201, 105, 135, 45);
					btnOrden.setIcon(new ImageIcon(getClass().getClassLoader().getResource("imagen/icons-word-processor.png.es.png")));
				}
				{
					btnCompra = new JButton();
					panelmenu.add(btnCompra);
					btnCompra.setText("Compra");
					btnCompra.setBounds(36, 171, 143, 48);
					btnCompra.setIcon(new ImageIcon(getClass().getClassLoader().getResource("imagen/comprar.png")));
				}
				{
					btnIngrediente = new JButton();
					panelmenu.add(btnIngrediente, "Center");
					btnIngrediente.setText("Ingrediente");
					btnIngrediente.setBounds(36, 31, 173, 45);
					btnIngrediente.setIcon(new ImageIcon(getClass().getClassLoader().getResource("imagen/comida_tomate.png")));
				}
				{
					btnCategoria = new JButton();
					panelmenu.add(btnCategoria);
					btnCategoria.setText("Categoria");
					btnCategoria.setBounds(352, 171, 159, 47);
					btnCategoria.setIcon(new ImageIcon(getClass().getClassLoader().getResource("imagen/comida-rapidapizza.png")));
				}
			}
			pack();
			this.setSize(556, 298);
		} catch (Exception e) {
		    //add your error handling code here
			e.printStackTrace();
		}
	}
	public void addListener(ActionListener actionListener){
		btnCategoria.addActionListener(actionListener);
		btnCompra.addActionListener(actionListener);
		btnIngrediente.addActionListener(actionListener);
		btnOrden.addActionListener(actionListener);
		btnProducto.addActionListener(actionListener);
	}

}
